nepetaleijontheoneandonly Posted January 2, 2014 Share Posted January 2, 2014 I'm making a character mod of Vanellope, and seeing as she's from Sugar Rush, and she starts out with ten pieces of taffy, I'd like to replace the health penalty with a health bonus. Can someone show me how to do that? Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/ Share on other sites More sharing options...
ColeenMcCleod Posted January 3, 2014 Share Posted January 3, 2014 Well, looking in the preparedfoods.lua, the taffy recipe shows as this: taffy = { test = function(cooker, names, tags) return tags.sweetener and tags.sweetener >= 3 and not tags.meat end, priority = 10, foodtype = "VEGGIE", health = -TUNING.HEALING_SMALL, hunger = TUNING.CALORIES_SMALL*2, perishtime = TUNING.PERISH_SLOW, sanity = TUNING.SANITY_MED, cooktime = 2, }, (bold is mine) I'd imagine removing that "-" from before the TUNING.HEALING_SMALL might do the trick? Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-397512 Share on other sites More sharing options...
NikMik Posted January 3, 2014 Share Posted January 3, 2014 Add to the modmain; AddPrefabPostInit("taffy", function(inst)if GetPlayer().prefab == "CHARACTER NAME" then health = DESIRED AMOUNTendend)That *should* work. Does for all the meats and veggies. Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-397531 Share on other sites More sharing options...
nepetaleijontheoneandonly Posted January 3, 2014 Author Share Posted January 3, 2014 thanks for the help guys but uhi was changing the name from wod to van so she wouldn't clash with other mods andshe turnedinvisible Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-397582 Share on other sites More sharing options...
NikMik Posted January 3, 2014 Share Posted January 3, 2014 (edited) Did you change the build name? In her anim folder? Edited January 3, 2014 by Mr. Tiddles Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-397590 Share on other sites More sharing options...
nepetaleijontheoneandonly Posted January 3, 2014 Author Share Posted January 3, 2014 Did you change the build name? In her anim folder?I didn't know i had to change that, oops!What should I change it to? just her name or something specific? Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-397596 Share on other sites More sharing options...
NikMik Posted January 3, 2014 Share Posted January 3, 2014 I didn't know i had to change that, oops!What should I change it to? just her name or something specific?van And make sure you download Matt's build renamer found here: http://forums.kleientertainment.com/files/go/c5b58baaddb578e700c23ae2053932be/matts-tools to rename the build. Don't actually click "rename" on it and change it, or else it won't work. Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-397618 Share on other sites More sharing options...
nepetaleijontheoneandonly Posted January 4, 2014 Author Share Posted January 4, 2014 SHE'S A TREE HELP Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-398548 Share on other sites More sharing options...
nepetaleijontheoneandonly Posted January 4, 2014 Author Share Posted January 4, 2014 Oh nevermind. Turns out I accidentally deleted the atlas file, oops! Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-398550 Share on other sites More sharing options...
NikMik Posted January 4, 2014 Share Posted January 4, 2014 Oh nevermind. Turns out I accidentally deleted the atlas file, oops!I've done that with one of my mods. I didn't have any back-ups, so I just went "Meh" and gave up. Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-398551 Share on other sites More sharing options...
nepetaleijontheoneandonly Posted January 4, 2014 Author Share Posted January 4, 2014 Add to the modmain; AddPrefabPostInit("taffy", function(inst)if GetPlayer().prefab == "CHARACTER NAME" then health = DESIRED AMOUNTendend)That *should* work. Does for all the meats and veggies. I get an error message saying GetPlayer is a nil value. Did I paste it wrong?I probably sound pretty dumb, huh? Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-398564 Share on other sites More sharing options...
NikMik Posted January 4, 2014 Share Posted January 4, 2014 I get an error message saying GetPlayer is a nil value. Did I paste it wrong?I probably sound pretty dumb, huh? Did you make "CHARACTER" NAME Van? Also, I got the thing wrong. It's not health = DESIRED AMOUNT, it's: inst.components.edible.healthvalue = DESIRED AMOUNT Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-398565 Share on other sites More sharing options...
nepetaleijontheoneandonly Posted January 4, 2014 Author Share Posted January 4, 2014 Did you make "CHARACTER" NAME Van? Also, I got the thing wrong. It's not health = DESIRED AMOUNT, it's: inst.components.edible.healthvalue = DESIRED AMOUNTYup, I did.It's really weird - When I start a new game I hear the audio for it (ie Maxwell speaking etc) but the screen shows an error message Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-398570 Share on other sites More sharing options...
NikMik Posted January 4, 2014 Share Posted January 4, 2014 Can you upload the mod in a .zip file so I can take a look at it? Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-398571 Share on other sites More sharing options...
nepetaleijontheoneandonly Posted January 5, 2014 Author Share Posted January 5, 2014 Can you upload the mod in a .zip file so I can take a look at it? Most of the images are placeholders by the wayvanellope mod_1.zip Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-399077 Share on other sites More sharing options...
NikMik Posted January 5, 2014 Share Posted January 5, 2014 (edited) Most of the images are placeholders by the wayAlright, got it. This is what a section of your modmain.lua looks like:GLOBAL.STRINGS.CHARACTERS.VAN.DESCRIBE.-- Let the game know Wod is a male, for proper pronouns during the end-game sequence.-- Possible genders here are MALE, FEMALE, or ROBOTtable.insert(GLOBAL.CHARACTER_GENDERS.FEMALE, "van")And this is what it SHOULD look like:GLOBAL.STRINGS.CHARACTERS.VAN.DESCRIBE.GetPlayer = GLOBAL.GetPlayer-- Let the game know Wod is a male, for proper pronouns during the end-game sequence.-- Possible genders here are MALE, FEMALE, or ROBOTtable.insert(GLOBAL.CHARACTER_GENDERS.FEMALE, "van")After fixing that, it's working fine for me.Now, to make her able to eat taffy, add (almost, you can set the health value to what you want) exactly this:AddPrefabPostInit("taffy", function(inst)if GetPlayer().prefab == "van" then inst.components.edible.healthvalue = TUNING.HEALING_TINYendend)Around just after the "assets" part of the modmain. Edited January 5, 2014 by Mr. Tiddles Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-399131 Share on other sites More sharing options...
nepetaleijontheoneandonly Posted January 14, 2014 Author Share Posted January 14, 2014 Alright, got it. This is what a section of your modmain.lua looks like:GLOBAL.STRINGS.CHARACTERS.VAN.DESCRIBE.-- Let the game know Wod is a male, for proper pronouns during the end-game sequence.-- Possible genders here are MALE, FEMALE, or ROBOTtable.insert(GLOBAL.CHARACTER_GENDERS.FEMALE, "van")And this is what it SHOULD look like:GLOBAL.STRINGS.CHARACTERS.VAN.DESCRIBE.GetPlayer = GLOBAL.GetPlayer-- Let the game know Wod is a male, for proper pronouns during the end-game sequence.-- Possible genders here are MALE, FEMALE, or ROBOTtable.insert(GLOBAL.CHARACTER_GENDERS.FEMALE, "van")After fixing that, it's working fine for me.Now, to make her able to eat taffy, add (almost, you can set the health value to what you want) exactly this:AddPrefabPostInit("taffy", function(inst)if GetPlayer().prefab == "van" then inst.components.edible.healthvalue = TUNING.HEALING_TINYendend)Around just after the "assets" part of the modmain. I'm really sorry for still being a bother.. But now she's not showing up on the character select. Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-403891 Share on other sites More sharing options...
NikMik Posted January 14, 2014 Share Posted January 14, 2014 I'm really sorry for still being a bother.. But now she's not showing up on the character select.I got it working fine. Here, you an take this if you want. Maybe read the modmain to see what/if you've made a mistake. And might I suggest making the lines a bit thicker? Would fit in a bit better. Van_working.zip Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-403901 Share on other sites More sharing options...
nepetaleijontheoneandonly Posted January 14, 2014 Author Share Posted January 14, 2014 I got it working fine. Here, you an take this if you want. Maybe read the modmain to see what/if you've made a mistake. And might I suggest making the lines a bit thicker? Would fit in a bit better. Van_working.zipThank you!!And yes, I'll keep that in mind when I eventually redo her sprite sheet Link to comment https://forums.kleientertainment.com/forums/topic/30694-remove-health-penalty-from-taffy/#findComment-403904 Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now